package com.neutech.neusys.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.neutech.neusys.mapper.DiseCategoryMapper;
import com.neutech.neusys.mapper.DiseaseMapper;
import com.neutech.neusys.service.DiseaseService;
import com.neutech.po.DiseCategory;
import com.neutech.po.Disease;

@Service
public class DiseaseServiceImpl implements DiseaseService {
	@Autowired
	private DiseaseMapper diseaseMapper;
	@Autowired
	private DiseCategoryMapper diseCategoryMapper;
	
	@Override
	public int addDisease(Disease disease){
		int num = diseaseMapper.addDisease(disease);
		return num;
	}
	
	@Override
	public List<DiseCategory> getDiseCategory() {
		List<DiseCategory> diseCategoryList = diseCategoryMapper.queryAll();
		return diseCategoryList;
	}
	
}
